﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Configuration;
using System.Xml;

namespace FastDFS.Client
{
    /// <summary>
    /// FastDFSSection块，在web.config中提供FastDFSSection块定义
    /// </summary>
    internal class FastDFSSection : ConfigurationSection
    {

        /// <summary>
        /// 主机地址
        /// </summary>
        [ConfigurationProperty("Host", DefaultValue = "localhost")]
        public string Host
        {
            get { return (string)this["Host"]; }
            set { this["Host"] = value; }
        }
        /// <summary>
        /// 端口号
        /// </summary>
        [ConfigurationProperty("Port", DefaultValue = "6379")]
        public int Port
        {
            get { return (int)this["Port"]; }
            set { this["Port"] = value; }
        }

        /// <summary>
        /// 默认的组
        /// </summary>
        [ConfigurationProperty("GroupName", DefaultValue = "group1")]
        public string GroupName
        {
            get { return (string)this["GroupName"]; }
            set { this["GroupName"] = value; }
        }

    }
}
